#define VMI_TOADDR(type, addr) \
    ((uint64_t)(type)<<63) | ((uint64_t)(addr>>56) & 0xFF), \
    ((uint64_t)addr>>48) & 0xFF, \
    ((uint64_t)addr>>40) & 0xFF, \
    ((uint64_t)addr>>32) & 0xFF, \
    ((uint64_t)addr>>24) & 0xFF, \
    ((uint64_t)addr>>16) & 0xFF, \
    ((uint64_t)addr>>8) & 0xFF, \
    ((uint64_t)addr) & 0xFF


#define VMI_I32(v) \
    (v>>24) & 0xFF, \
    (v>>16) & 0xFF, \
    (v>>8) & 0xFF, \
    (v) & 0xFF
   